<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<style type="text/css">
			*{
				margin: 0;
				padding: 0;
			}
			div {
				width: 100px;
				height: 50px;
				position: absolute;
				top: 50%;
				left: 50%;
			}
			.box1{
				background: pink;
			}
			.box2{
				background: lightblue;
				/*正参数值,沿顺时针方向旋转;负值沿逆时针*/
				transform: rotate(-45deg);   /*一个参数值时，表示绕z轴旋转*/
			}
		</style>
	</head>
	<body>
		<div class="box1"></div>
		<div class="box2"></div>
	</body>
</html>
